#pragma once

#include "BaseEntity.h"
#include "SFML/System.hpp"
#include "SFML/Graphics.hpp"
#include "PhysicsObject.h"

class GameLogic
{
private:
	BaseEntity* Player;
	BaseEntity* ViewCam;

	sf::Text EntityCount;
	sf::Text PlayerScore;
	sf::Text FrameTime;
	sf::Sprite HealthBar;

	float NextFrameTime;
	float NextEnemy;
	int Score;
public:
	GameLogic(void);
	~GameLogic(void);

	void Initialize();
	void OnCollision(BaseEntity* ent1, BaseEntity* ent2, CollisionData* Info);
	void Tick();
	void OnEntityCreated(BaseEntity* ent);
	void OnEntityDestroyed(BaseEntity* ent); //Right before its killed
	void OnKeyPressed(sf::Keyboard::Key Key, sf::RenderWindow &render);

	void DrawHUD(sf::RenderWindow *render);
};

